home *** CD-ROM | disk | FTP | other *** search
/ ETO Development Tools 1 / ETO Development Tools 1.iso / Essentials / MacApp Documentation / MacApp AppleLink Messages / MacApp.Tech$ Aug 89 / X0044-Re ß9 heartburn-Aug89 < prev    next >
Encoding:
Text File  |  1989-08-22  |  4.8 KB  |  121 lines  |  [TEXT/GEOL]

  1. Item    5484304                         12-Aug-89        22:24
  2.  
  3. From:   MACDTS                          Macintosh Developer Tech. Supt.,APL
  4.  
  5. To:     JOHNMARK                        Stanford U, John Agosta
  6.  
  7. cc:     MACAPP.TECH$                    MACAPP Tech
  8.  
  9. Sub:    Re: ß9 heartburn
  10.  
  11. John,
  12.  
  13. I'm sorry that things aren't working out. Hopefully, what Chris suggested and
  14. some of what I suggest will help:
  15.  
  16. >Why does MABuild defaults enforce case sensitivity in calling asm?  My
  17. >previously assembled files didn't assemble until I traced down all the case
  18. >changes in the assembly source code. (Also I got a linker error until I
  19. changed
  20. >an asm procedure label to upper case. ) Hey, I'd  never admit to touching
  21. >assembly code.  Someone who gave me the .o files was kind enough to include
  22. the
  23. >.a sources also.  I write high level code, like objects.
  24.  
  25. I don't know *WHY* MacApp enforces case sensitivity in the Assembler, but this
  26. is easily turned off. It is set in "Startup" in the MacApp folder. Look for
  27. where {MABuildDefaults} is defined. You'll see that there is a line "-Asm
  28. '-case on'". This can be cut out if it's causing you problems.
  29.  
  30. >When I try to "pascal -p -c -i{MAPinterfaces} " my sources, to check them for
  31. >syntax, I get errors about unknown compile flags - e.g. qDebug, etc. Where
  32. does
  33. >MABuild set these?
  34.  
  35. "qDebug" and a buttload of other compile time variables are set up during the
  36. MABuild process. What you may be able to do is leverage off of MABuild by
  37. including the "-c" option on its command line:
  38.  
  39.     MABuild -pascal '-c -p' MyProgram
  40.  
  41. This may not be as fast as you've experienced in the past with non-MacApp
  42. programs, but it should work.
  43.  
  44. >In Nothing.p -
  45. >RegisterStdType('TnothingView', 'dflt');
  46. >
  47. >What is this? I guess it asociates a view resource with my view. Where is it
  48. >documented? p. 92 of the General Reference, which describes "RegisterType" is
  49. >somewhat opaque (and apparently already obsolete.)
  50.  
  51. You should find the following comments in the {MALibraries}Defaults.r file.
  52.  
  53. resource 'view' (kDefaultViewID, "kDefaultViewID", purgeable) {
  54.    {
  55.       root, 'DFLT', {0, 0}, {134, 414}, sizeFixed, sizeFixed, shown, enabled,
  56.       DefaultView    {""}        // A ClassName can be put in this string
  57.                                  // or do a RegisterStdType to point to
  58.                                  // something to create for a "Default View"
  59.    }
  60. };
  61.  
  62. Granted that that's not best place to put documentation, but that's where it
  63. is. In the near future, hidden marvels like this will be documented in the
  64. MacApp documentation suite, but until then, you can only find gems like these
  65. by spending a few evenings ignoring your family and reading the source code
  66. (that's probably why I don't even have a family...). If you look this up, check
  67. out the rest of the file while you're there, as there's lots of new neat stuff
  68. that MacApp now provides automagically™ for you:
  69.  
  70. >In ß5, I avoided handle dereference checking, a new feature in pascal 3.0, by
  71. >aliasing pascal to "pascal -h".
  72.  
  73. Chris correctly notes that you can use the "-h" option by attaching it to the
  74. "-pascal" option. However, I would also like to add that using this convenient
  75. method is asking for trouble. You can easily hide instances where you program
  76. can get into a situation where it will crash. Instead, if there are legitimate
  77. and *SAFE* cases where you need to pass a certain instance variable as a VAR
  78. and the Pascal compiler complains about it, you can turn off the checking
  79. locally with the {$PUSH}{$H-} and {$POP} options.
  80.  
  81. >Does MacApp really turn off all handle dereference checking during compile?
  82.  
  83. No, it doesn't. It used to be that you needed to do that if you were using
  84. MacApp 2.0ß5, but this is not longer necessary with MacApp 2.0ß9.
  85.  
  86. >Now that the link works, when I run, the application crashes during
  87. >initialization.
  88. >In MacsBug the sc is
  89. >
  90. >myApplication +0024
  91. >DoFailure  +0026
  92. >etc..
  93. >
  94. >where myApplication +0024 is
  95. >INITUMAPAPP
  96. >-apparently the InitUMacApp(8);
  97. >call.
  98.  
  99. I don't know off the top of my head what's going on here. I did a "DumpObj" on
  100. "{MALibraries}.Debug Files:UFailure.a.o" (where DoFailure is) and found that
  101. "DoFailure  +0026" corresponds to the second of these two lines.
  102.  
  103. 00000024:        Move.L(A0)+,A0   ; get address of failure handler
  104. 00000026:        Jsr   (A0)         ; call failure handler
  105.  
  106. So it looks to me that there may not be a valid failure handler set up at the
  107. time your application fails. I don't know why not, as I think MacApp provides a
  108. tippy-top level failure handler, but it may be something along those lines.
  109.  
  110. >Sorry, I haven't had time to catch up on the MACAPP.TECH traffic, so I
  111. >am not sure if any of these questions have been discussed.
  112. >Time to find a dandelion patch to go for a walk in.  -johnmark
  113.  
  114. There are no more dandelion patches <sob!>. But the anxiety closet lives on...
  115.  
  116. - Keith Rollin
  117. - Apple Developer Technical Support
  118.  
  119.  
  120.  
  121.